From 264cab2b5279fc5dcc7ae7be868366f76031c7b9 Mon Sep 17 00:00:00 2001 From: Lapo Calamandrei Date: Wed, 22 Oct 2014 20:46:54 +0200 Subject: [PATCH] Adwaita: add borders to menus in a non composited env https://bugzilla.gnome.org/show_bug.cgi?id=738800 --- gtk/resources/theme/Adwaita/_common.scss | 9 ++++++++- gtk/resources/theme/Adwaita/gtk-contained-dark.css | 9 +++++++-- gtk/resources/theme/Adwaita/gtk-contained.css | 9 +++++++-- 3 files changed, 22 insertions(+), 5 deletions(-) diff --git a/gtk/resources/theme/Adwaita/_common.scss b/gtk/resources/theme/Adwaita/_common.scss index 4300ec8353..3d1efb75ca 100644 --- a/gtk/resources/theme/Adwaita/_common.scss +++ b/gtk/resources/theme/Adwaita/_common.scss @@ -1530,6 +1530,8 @@ column-header.button.dnd { // for treeview-like derive widgets margin: 4px; padding: 0px; background-color: $base_color; + border: 1px solid $borders_color; // adds borders in a non composited env + .csd & { border: none; } // axes borders in a composited env .menuitem { text-shadow: none; padding: 4px; @@ -3078,6 +3080,8 @@ GtkVolumeButton.button { padding: 8px; } box-shadow: 0 3px 9px 1px transparentize(black, 0.5), 0 0 0 1px $_wm_border; //doing borders with box-shadow + // FIXME rationalize window-frame shadows + /* this is used for the resize cursor area */ margin: 10px; @@ -3088,8 +3092,11 @@ GtkVolumeButton.button { padding: 8px; } &.tiled { border-radius: 0; } + &.popup { + box-shadow: none; + } &.csd { - &.popup { + .popup { border-radius: 0; box-shadow: 0 1px 2px transparentize(black, 0.8), 0 0 0 1px transparentize($_wm_border,0.1); diff --git a/gtk/resources/theme/Adwaita/gtk-contained-dark.css b/gtk/resources/theme/Adwaita/gtk-contained-dark.css index 9d6fcd6111..67b9ee8782 100644 --- a/gtk/resources/theme/Adwaita/gtk-contained-dark.css +++ b/gtk/resources/theme/Adwaita/gtk-contained-dark.css @@ -2048,7 +2048,10 @@ column-header .titlebar .button.titlebutton, .menu { margin: 4px; padding: 0px; - background-color: #292929; } + background-color: #292929; + border: 1px solid #1c1f1f; } + .csd .menu { + border: none; } .menu .menuitem { text-shadow: none; padding: 4px; } @@ -4215,7 +4218,9 @@ GtkVolumeButton.button, .header-bar GtkVolumeButton.button.titlebutton, box-shadow: 0 2px 6px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(28, 31, 31, 0.9); } .window-frame.tiled { border-radius: 0; } - .window-frame.csd.popup { + .window-frame.popup { + box-shadow: none; } + .window-frame.csd .popup { border-radius: 0; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(28, 31, 31, 0.8); } .window-frame.csd.tooltip { diff --git a/gtk/resources/theme/Adwaita/gtk-contained.css b/gtk/resources/theme/Adwaita/gtk-contained.css index 992e177325..77d2701373 100644 --- a/gtk/resources/theme/Adwaita/gtk-contained.css +++ b/gtk/resources/theme/Adwaita/gtk-contained.css @@ -2045,7 +2045,10 @@ column-header .titlebar .button.titlebutton, .menu { margin: 4px; padding: 0px; - background-color: #ffffff; } + background-color: #ffffff; + border: 1px solid #a1a1a1; } + .csd .menu { + border: none; } .menu .menuitem { text-shadow: none; padding: 4px; } @@ -4376,7 +4379,9 @@ GtkVolumeButton.button, .header-bar GtkVolumeButton.button.titlebutton, box-shadow: 0 2px 6px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.18); } .window-frame.tiled { border-radius: 0; } - .window-frame.csd.popup { + .window-frame.popup { + box-shadow: none; } + .window-frame.csd .popup { border-radius: 0; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.13); } .window-frame.csd.tooltip { -- 2.30.2